<template>
  <view id="main">
    <yz-bg themeBg></yz-bg>
    <view class="title flex">
      <view class="title-text fs_16"> 工作台 </view>
      <view class="handle">
        <yz-exitlogin />
      </view>
    </view>

    <view class="content flex">
      <view @tap="handleClick('TagStatus1')" class="content_item">
        <image src="@/static/icon/allocate.png" />
        <view class="content_item_text">待分配</view>
      </view>
      <view @tap="handleClick('TagStatus2')" class="content_item">
        <image src="@/static/icon/treatment.png" />
        <view class="content_item_text">诊疗中</view>
      </view>
      <view @tap="handleClick('TagStatus3')" class="content_item">
        <image src="@/static/icon/evacuation.png" />
        <view class="content_item_text">后送伤票</view>
      </view>
    </view>
  </view>
</template>

<script setup lang="ts">
import { useWoundedfzStore } from '@/stores/modules/woundedfz'
const woundedStore = useWoundedfzStore()
const handleClick = (status: string): void => {
  woundedStore.clearDate()
  woundedStore.TagStatus = status
  uni.navigateTo({
    url: `/pages/wounded/wounded?status=${status}`,
  })
}
</script>

<style lang="scss" scoped >
#main {
  .title {
    justify-content: space-between;
    padding: 10px;
    position: relative;
    z-index: 99;
  }
  .content {
    padding: 10px;
    justify-content: space-between;
    .content_item {
      position: relative;
      width: 102px;
      height: 104px;
      image {
        width: 102px;
        height: 104px;
      }
      .content_item_text {
        display: flex;
        justify-content: center;
        align-items: center;
        height: 30px;
        color: rgba(255, 255, 255, 0.8);
        font-size: 14px;
        width: 100%;
        position: absolute;
        background: rgba(255, 255, 255, 0.1);
        bottom: 0;
        left: 0;
      }
    }
  }
}
</style>
